<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .wrapper {
            width: 840px;
            height: 420px;
            background: url(./1.jpg) no-repeat center / cover;
            padding: 100px 250px;
            box-sizing: border-box;
        }
    </style>
</head>
<body>
    <div class="wrapper">
        <strong>年会抽奖</strong>
        <h1>一等奖：<span id = "one">???</span></h1>
        <h2>二等奖：<span id = "two">???</span></h2>
        <h3>三等奖：<span id = "three">???</span></h3>
    </div>
    <script>
        const personArr = ['周杰伦', '刘德华', '周星驰', 'pink', '张学友']

        const random = Math.floor(Math.random() * personArr.length)
        const one = document.querySelector('#one')
        one.innerHTML = personArr[random]
        personArr.splice(random, 1)

        const random2 = Math.floor(Math.random() * personArr.length)
        const two = document.querySelector('#two')
        two.innerHTML = personArr[random2]
        personArr.splice(random2, 1)

        const random3 = Math.floor(Math.random() * personArr.length)
        const three = document.querySelector('#three')
        three.innerHTML = personArr[random3]
        personArr.splice(random3, 1)
    </script>
</body>
</html>